show: function() {
this._appDisplay.show();
- },
-
- hide: function() {
}
};
Signals.addSignalMethods(Sideshow.prototype);
// TODO - recalculate everything when desktop size changes
this._recalculateSize();
- this._workspaces = new Workspaces.Workspaces(
- this._workspaceGridX, this._workspaceGridY,
- this._workspaceGridWidth, this._workspaceGridHeight);
- this._group.add_actor(this._workspaces._group);
-
this._sideshow = new Sideshow(this._group, this._workspaceGridX - 10);
this._sideshow.connect('activated', function(sideshow) {
// TODO - have some sort of animation/effect while
this._recalculateSize();
this._sideshow.show();
- this._workspaces.show();
- this._workspaces._group.raise_top();
+
+ this._workspaces = new Workspaces.Workspaces(
+ this._workspaceGridX, this._workspaceGridY,
+ this._workspaceGridWidth, this._workspaceGridHeight);
+ this._group.add_actor(this._workspaces.actor);
+ this._workspaces.actor.raise_top();
// All the the actors in the window group are completely obscured,
// hiding the group holding them while the overlay is displayed greatly
return;
this._workspaces.hide();
- this._sideshow.hide();
// Dummy tween, just waiting for the workspace animation
Tweener.addTween(this,
onCompleteScope: this
});
},
-
+
_hideDone: function() {
let global = Shell.Global.get();
this.visible = false;
global.window_group.show();
- this._group.lower_bottom();
this._group.hide();
- this._workspaces.hideDone();
+
+ this._workspaces.destroy();
+ this._workspaces = null;
},
_deactivate : function() {
Workspaces.prototype = {
_init : function(x, y, width, height) {
-
- this._group = new Clutter.Group();
+ this.actor = new Clutter.Group();
this._x = x;
this._y = y;
this._width = width;
this._height = height;
this._workspaces = [];
- },
- show : function() {
let global = Shell.Global.get();
-
let windows = global.get_windows();
let activeWorkspace = global.screen.get_active_workspace_index();
this._workspaces = [];
for (let w = 0; w < global.screen.n_workspaces; w++) {
this._workspaces[w] = new Clutter.Group();
- this._group.add_actor(this._workspaces[w]);
+ this.actor.add_actor(this._workspaces[w]);
}
this._createDesktopActors(windows);
});
}
},
-
- hideDone : function() {
+
+ destroy : function() {
for (let w = 0; w < this._workspaces.length; w++) {
this._workspaces[w].destroy();
}